package com.wang.exam.mapper;

import com.wang.exam.pojo.Student;
import com.wang.exam.pojo.Teacher;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Mapper
@Repository
public interface StudentMapper {
    //id查询
    List<Student> getStudentById(Integer student_id);
    //分页查询学生的登录信息
    List<Student> getStudentList(@Param("page")int page, @Param("rows")int rows);
    List<Student> getStudent(String keyword);
    //查询学生的总记录
    int getCount();
    //删除选中
    int deleteId(String[] ids);
    //添加学生
    int addStudent(Student student);
    //修改学生
    int updateStudent(@Param("student_id")Integer student_id,@Param("student_name")String student_name,@Param("student_pwd")String student_pwd,@Param("major_id")Integer major_id);
    //修改学生密码
    int upStudentPassWord(Map<String,Object> map);
    //删除学生
    int deleteStudent(Integer student_id);
}
